<!DOCTYPE html>
<html>
{include file="head.html"}
<body>
{include file="category/nav.html"}
<div class="rbox">
<form method="post" action="{$appadmin}?m=category&a=save">
<input type="hidden" name="catid" value="{$data.catid}">
{if $parent}
<input type="hidden" name="pid" value="{$parent.catid}" />
{/if}
<table width="100%" class="table table-bordered">
   <tr>
    <td>名称：</td>
    <td><label for="cname"></label>
      <input name="cname" type="text" id="cname" value="{$data.cname}"></td>
  </tr>
   
  {if $catlist} 
  <tr>
      <td>上级分类：</td>
      <td><select name="pid" >
      <option value="0">请选择</option>
      	{foreach item=c from=$catlist}
                <option value="{$c.catid}" {if $data.pid eq $c.catid} selected="selected"{/if}>{$c.cname}</option>
                {foreach item=c_2 from=$c.child}
                	<option value="{$c_2.catid}" {if $data.pid eq $c_2.catid} selected="selected"{/if} class="o_c_2">|__{$c_2.cname}</option>
                    {foreach item=c_3 from=$c_2.child}
                    <option value="{$c_3.catid}" {if $data.pid eq $c_3.catid} selected="selected"{/if} class="o_c_3"> |____{$c_3.cname}</option>
                    {/foreach}
                {/foreach}
                {/foreach}
      </select></td>
  </tr>
  
  {/if}
   
 
  
  <tr>
    <td>状态：</td>
    <td><input name="bstatus" type="radio" id="radio2" value="1" {if $data.bstatus neq 2} checked="checked" {/if} />
      显示
        <input type="radio" name="bstatus" id="radio3" value="2" {if $data.bstatus eq 2} checked="checked" {/if} />
        隐藏</td>
  </tr>
  
  <tr>
    <td>排序：</td>
    <td><input name="orderindex" type="text" id="orderindex" value="{if $data}{$data.orderindex}{else}9999{/if}"></td>
  </tr>
   
  
  <tr>
    <td>seo标题：</td>
    <td><textarea name="title" id="title"  class="w600 h100">{$data.title}</textarea></td>
  </tr>
  <tr>
    <td>seo关键词：</td>
    <td><textarea name="keywords" id="keywords"  class="w600 h100">{$data.keywords}</textarea></td>
  </tr>
  <tr>
    <td>seo描述：</td>
    <td><textarea name="description" id="description"  class="w600 h100">{$data.description}</textarea></td>
  </tr>
  
   
    <tr>
    <td align="right">图标：</td>
    <td>
    <div class="upload-row">
        <div class="btn-upload">
        上传图片
          <input type="file" name="upimg" class="btn-upload-file" id="upimg" onChange="uploadImg('upimg')">
          </div>
          <label  id="loading" style="color:red; display:none;">正在上传中...</label>
          <input type="hidden" name="logo" class="upload-field" id="imgurl" value="{$data.logo}">
          <span   class="upload-show">
          {if $data.logo}
          <img src="{$data.logo|IMAGES_SITE}.100x100.jpg">
          {/if}
          </span>
      </div>
      </td>
  </tr>
  <tr>
    <td>列表模板：</td>
    <td><input name="list_tpl" type="text" id="list_tpl" class="w600" value="{$data.list_tpl}" /></td>
  </tr>
  <tr>
    <td>详情模板：</td>
    <td><input name="show_tpl" type="text" id="show_tpl" class="w600" value="{$data.show_tpl}" /></td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td><input type="submit" name="button" id="button" value="保存" class="btn" /></td>
  </tr>
  
</table>
</form>
</div>
 
 
{include file='footer.html'}
</body>
</html>